function initDb() {
  var db = new GearsDB('feedreader');
  
  //db.dropTable("feeds");
  //db.dropTable("feeds_items");
  
  db.run('CREATE TABLE feeds ('+
  'id integer not null primary key autoincrement,'+
  'feedtype varchar(255),'+
  'title varchar(255),'+
  'feedUrl varchar(255),'+
  'link varchar(255),'+
  'description text,updated varchar(255))');

	db.run('CREATE TABLE feed_items ('+
    'id INTEGER PRIMARY KEY AUTOINCREMENT,'+
    'feed_id INTEGER,'+
    'item_title VARCHAR(255),'+
    'item_link VARCHAR(255),'+
    'item_description TEXT,'+
    'item_updated INT)');		 

	db.run('CREATE TABLE preferences ('+
    'id INTEGER PRIMARY KEY AUTOINCREMENT,'+
    'online varchar(1))');	
	
   db.run('insert into preferences (online) values (?)', ['Y']);	
   
  //db.run('insert into feeds (id, feedtype, title, link, description, updated) values (?, ?, ?, ?, ?, ?)', [1, 'RSS', 'Ajaxian', 'http://feeds.feedburner.com/ajaxian', 'Cleaning up the web with Ajax', '28 Nov 2007']);
}
